class Student {
    private String name;
    private int age;
    private double grade;

    public Student(String newName, int newAge, double newGrade) {
        this(newAge,newGrade);
        name = newName;
        System.out.println("构造方法Student(String,int,double)被调用");
    }
    public Student( int newAge, double newGrade) {
        this(newGrade);
        age = newAge;
        System.out.println("构造方法Student(int,double)被调用");
    }
    public Student(double newGrade) {
        this();
        grade = newGrade;
        System.out.println("构造方法Student(double)被调用");
    }
    public Student() {
        System.out.println("构造方法Student被调用");
    }
    void setGrade(double newGrade) {
        double grade = 0;
        grade = newGrade;
    }
    double getGrade() {
        return grade;
    }
}
public class Zuoye {
    public static void main(String[] args) {
        Student s = new Student("lixia",25,86.5);
        s.setGrade(99);
        System.out.println("成绩是："+s.getGrade());
    }
}
